package com.settlement.system.mapper;

import com.settlement.system.common.exception.ServiceException;
import com.settlement.system.model.entity.common.TblCustomizedExporeMain;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 自定义导出主表 Mapper 接口
 *
 * @author Ximi
 * @since 2020-11-17
 */
public interface TblCustomizedExporeMainMapper extends BaseMapper {

    /**
     * 通过菜单名称和自定义导出名称获取数据
     *
     * @param customizedExporeName
     * @param menuName
     * @return
     */
    public TblCustomizedExporeMain getByBothName(@Param("menuName") String menuName,
                                                 @Param("customizedExporeName") String customizedExporeName);

    /**
     * 获取自定义导出的名称
     *
     * @param menuName
     * @return
     * @throws ServiceException
     */
    public List<String> getCustomizedExporeNameByMenuName(@Param("menuName") String menuName) throws ServiceException;

    /**
     * 通过ID修改自定义导出的名称
     *
     * @param customizedExporeName
     * @param id
     * @throws ServiceException
     */
    public void updateCustomizedExporeNameById(@Param("customizedExporeName") String customizedExporeName,
                                               @Param("id") String id) throws ServiceException;

}

